#!/bin/bash
function d-push() {
  imageUrl=$1
  image=${imageUrl##*/}
  proxyUrl=$2
  echo ""
  echo -e "${ORANGE}[Proxy:] $proxyUrl"
  echo -e "[Image:] $image"
  tput sgr0

  docker tag  $imageUrl $proxyUrl$image
  docker push $proxyUrl$image
  echo ""
  echo -e "${ORANGE}[Delete:] Delete Proxy image."
  docker rmi $proxyUrl$image
}

d-push $@